const http = require('../utils/http')

const HTTP = new http.HTTP()

// 查我加入的社团
export function getMyCommunity(volunteerId, callback) {
  let params = {
    volunteerId
  }
  HTTP.request('/community/getJoinedCommunity', 'GET', params, res => {
    callback(res)
  })
}

// 退出社团
export function outCommunity(communityId, callback) {
  let params = {
    communityId
  }
  HTTP.request('/community/quitCommunity/' + communityId, 'DELETE', params, res => {
    callback(res)
  })
}